package lingwu;

public class Demo03 {   //递归求阶乘
    public static void main(String[] args) {
        System.out.println(method(7));
    }
    public static long method(int n){
        if(n>1){
            return n*method(n-1);
        }else{
            return 1;
        }
    }
}
